<template>
  <div class="wf-box">
    <van-nav-bar
      :title="hardText"
      left-text="返回"
      right-text="按钮"
      left-arrow
      @click-left="onClickLeft"
    />
    <router-view></router-view>
  </div>
</template>
<script>

export default {
  data() {
    return {
      hardText: "服务列表",
    };
  },
  created() {
    this.hardText = this.$route.query.hardText
      ? this.$route.query.hardText
      : "服务列表";
  },
  beforeUpdate() {
    this.hardText = this.$route.query.hardText
      ? this.$route.query.hardText
      : "服务列表";
  },
  methods: {
    onClickLeft() {
      // console.log("aaaa");
      history.back();
    },
  },
};
</script>

<style lang="scss" scoped>
</style>